/**
 * @file audio.c
 * @author Sevenfite (Sevenfite@163.com)
 * @brief 音响抽象层
 * @version 0.1
 * @date 2024-05-20
 * 
 * @copyright Copyright (c) 2024
 * 
 */
#include "audio.h"
#include "C_code_Log.h"
#include "usart.h"
#include "stdbool.h"
#include <string.h>

static bool audio_TransmitData(const char *data);
void audio_init(void) {
    LOG_INFO("audio init\n");
}

void audio_play(const char *audio) {
    LOG_INFO("audio play: %s\n", audio);
}
static bool audio_TransmitData(const char *data) {
    if( HAL_UART_Transmit(&huart3, (uint8_t *)data, strlen(data), HAL_MAX_DELAY)==HAL_OK)
    {
        return true;
    }
    return false;
}